package com.riant.dayo2.demo1;

import java.util.Date;

/**
 * @Classname Test1
 * @Description TODO
 * @Date 2021/2/26 19:56
 * @Created by 张斌
 */
public class Test1 {

    public static void main(String[] args) throws IllegalAccessException, InstantiationException, NoSuchMethodException {
        Class<?> cls=String.class;
        cls.getDeclaredFields();
        cls.getFields();
        cls.getConstructor(String.class);
        System.out.println(cls.getName());
        String str=(String)cls.newInstance();
        System.out.println(str.getClass().getClassLoader());
        String s="str";
        System.out.println(s.getClass().getClassLoader());

        Integer  a=10;
        System.out.println(a.getClass().getClassLoader());
        Test1 test1=new Test1();
        System.out.println(test1.getClass().getClassLoader());
        System.out.println(Date.class.getClassLoader());
    }
}
